package com.guoxin.chapter4.reentractlock.lockinterruptiblytest2;

public class Run {
	public static void main(String[] args) throws InterruptedException {
		final Service service = new Service();
		Runnable runnable = new Runnable() {
			public void run() {
				service.waitMethod();
			}
		};

		new Thread(runnable, "A").start();
		Thread.sleep(500);
		Thread b = new Thread(runnable, "B");
		b.start();
		b.interrupt();
		System.out.println("main end");
	}
}
